ODAC

TMemDataSet.SetRange Method

Sets the starting and ending values of a range, and applies it.

Class

TMemDataSet

Syntax

procedure SetRange(const StartValues: array of System.TVarRec; const EndValues: array of System.TVarRec; StartExlusive: Boolean = False; EndExclusive: Boolean = False);

Parameters
StartValues
Indicates the field values that designate the first record in the range. In C++, StartValues_Size is the index of the last value in the StartValues array.
EndValues
Indicates the field values that designate the last record in the range. In C++, EndValues_Size is the index of the last value in the EndValues array.
StartExlusive
Iindicates the upper and lower boundaries of the start range.
EndExclusive
Indicates the upper and lower boundaries of the end range.

Remarks

Call SetRange to specify a range and apply it to the dataset. The new range replaces the currently specified range, if any.

SetRange combines the functionality of SetRangeStart, SetRangeEnd, and ApplyRange in a single procedure call. SetRange performs the following functions:

After a call to SetRange, the cursor is left on the first record in the range.

Note: StartValues or EndValues must contain values for the fields specified in the IndexFieldNames property. To limit the number of fields used to set the range, use the RangeFieldCount property.

See Also

© 1997-2026 Devart. All Rights Reserved. Request Support DAC Forum Provide Feedback